//
//  PhoneAudioView.swift
//  onemeetingmac
//
//  Created by 张衡 on 2020/3/13.
//  Copyright © 2020 onemeeting. All rights reserved.
//

import Foundation

class PhoneAudioView: NSView {
    
    override init(frame frameRect: NSRect) {
        super.init(frame: frameRect)
        self.setupUI()
    }
    
    required init?(coder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    func setupUI()  {
        
        self.addSubview(boardView)
        boardView.snp.makeConstraints { (make) in
            make.width.equalToSuperview().offset(-100)
            make.centerX.equalToSuperview()
            make.height.equalTo(200)
            make.top.equalTo(20)
        }
        
        boardView.zh_border(radius: 0, borderColor: color_gray(250), borderWidth: 1)
        
        boardView.addSubview(texView)
        texView.snp.makeConstraints { (make) in
            make.edges.equalToSuperview().inset(NSEdgeInsetsMake(20, 20, 20, 20))
        }
        
    }
    
    lazy var boardView: NSView = {
        let view = NSView()
        view.wantsLayer = true
        return view
    }()
    lazy var texView: BaseTextView = {
        let view = BaseTextView()
        view.font = NSFont.systemFont(ofSize: 14)
        view.txView.textColor = NSColor.black
        view.txView.string = "___ 邀请您参加腾讯会议\n会议主题：___的快速会议\n会议时间：2020/3/13 18:03-19:03\n\n点击链接直接加入会议：\nhttps://meeting.tencent.com/s/5nyFg58df74af\n\n会议 ID：417 843 749\n\n手机一键拨号入会\n\n+8675536550000,,,,417843749#,# (中国大陆)\n+85230018898,,,2,417843749#,# (中国香港)\n\n根据您的位置拨号\n+8675536550000 (中国大陆)\n+85230018898 (中国香港)"
        return view
    }()
}
